package com.ruoyi.sale.domain;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 商品销售对象 sale
 * 
 * @author ruoyi
 * @date 2024-09-26
 */
public class Sale extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** ID */
    private Integer id;

    /** 商品ID */
    @Excel(name = "商品ID")
    private Integer productId;

    /** 客户ID */
    @Excel(name = "客户ID")
    private Integer customerId;

    /** 支付类型 */
    @Excel(name = "支付类型")
    private String paymentType;

    /** 销售时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "销售时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date saleTime;

    /** 操作人ID */
    @Excel(name = "操作人ID")
    private Long operatorId;

    /** 销售数量 */
    @Excel(name = "销售数量")
    private Integer saleQuantity;

    /** 商品规格 */
    @Excel(name = "商品规格")
    private String productSpec;

    public String getProductName() {
        return productName;
    }

    public void setProductName(String productName) {
        this.productName = productName;
    }

    public String getCustomerName() {
        return customerName;
    }

    public void setCustomerName(String customerName) {
        this.customerName = customerName;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    @Excel(name = "商品名字")
    private String productName;
    @Excel(name = "客户名字")
    private String customerName;
    @Excel(name = "操作人名字")
    private String userName;

    /** 销售价格 */
    @Excel(name = "销售价格")
    private BigDecimal salePrice;

    /** 销售总价格 */
    @Excel(name = "销售总价格")
    private BigDecimal saleTotalPrice;

    public void setId(Integer id) 
    {
        this.id = id;
    }

    public Integer getId() 
    {
        return id;
    }
    public void setProductId(Integer productId) 
    {
        this.productId = productId;
    }

    public Integer getProductId() 
    {
        return productId;
    }
    public void setCustomerId(Integer customerId) 
    {
        this.customerId = customerId;
    }

    public Integer getCustomerId() 
    {
        return customerId;
    }
    public void setPaymentType(String paymentType) 
    {
        this.paymentType = paymentType;
    }

    public String getPaymentType() 
    {
        return paymentType;
    }
    public void setSaleTime(Date saleTime)
    {
        this.saleTime = saleTime;
    }

    public Date getSaleTime()
    {
        return saleTime;
    }
    public void setOperatorId(Long operatorId) 
    {
        this.operatorId = operatorId;
    }

    public Long getOperatorId() 
    {
        return operatorId;
    }
    public void setSaleQuantity(Integer saleQuantity) 
    {
        this.saleQuantity = saleQuantity;
    }

    public Integer getSaleQuantity() 
    {
        return saleQuantity;
    }
    public void setProductSpec(String productSpec) 
    {
        this.productSpec = productSpec;
    }

    public String getProductSpec() 
    {
        return productSpec;
    }
    public void setSalePrice(BigDecimal salePrice) 
    {
        this.salePrice = salePrice;
    }

    public BigDecimal getSalePrice() 
    {
        return salePrice;
    }
    public void setSaleTotalPrice(BigDecimal saleTotalPrice) 
    {
        this.saleTotalPrice = saleTotalPrice;
    }

    public BigDecimal getSaleTotalPrice() 
    {
        return saleTotalPrice;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("productId", getProductId())
            .append("customerId", getCustomerId())
            .append("paymentType", getPaymentType())
            .append("saleTime", getSaleTime())
            .append("operatorId", getOperatorId())
            .append("saleQuantity", getSaleQuantity())
            .append("productSpec", getProductSpec())
            .append("salePrice", getSalePrice())
            .append("saleTotalPrice", getSaleTotalPrice())
            .append("remark", getRemark())
            .toString();
    }
}
